home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 3 / BBS in a box - Trilogy III.iso / Files / System7 tools / Frontier / table.uniqueName / table.uniqueName verb < prev    next >
Encoding:
Text File  |  1992-06-12  |  896 b   |  36 lines  |  [TEXT/GEOL]

  1. Enclosure: table.uniqeName.pkg
  2.  
  3.  
  4. Verb
  5.     table.uniqueName
  6.  
  7. Syntax
  8.     table.uniqueName (prefix, tableAdr)
  9.  
  10. Parameters
  11.     prefix is a string that's used in contructing the unique name.
  12.     tableAdr is the address of a table that's about to get a new element.
  13.  
  14. Action
  15.     Iterates over names in the table to return a name that isn't in use.
  16.  
  17. Returns
  18.     An address of an item in the table that doesn't exist, it's safe to assign
  19. to.
  20.  
  21. Examples
  22.     table.uniqueName ("item", @scratchpad)
  23.           « scratchpad.item1
  24.     table.uniqueName ("item", @scratchpad)^ = 12
  25.           « 12
  26.     table.uniqueName ("item", @scratchpad)
  27.           « scratchpad.item2
  28.  
  29. Notes
  30.     Use this verb when you're adding an item to a table that contains several
  31. objects of the same type.
  32.     An example: you could use this verb to safely add an item to a table of
  33. file paths or email accounts.
  34.  
  35. Author: EL.GRANDE
  36.